@echo off

echo \"install the ant!\
echo unarchive the ant.
::%cd%/7z/7za.exe x -aoa apache*.zip
cd %cd%/apache*/

echo the current folder is %cd%

set regpath=HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment
set evname=ANT_HOME
set ANTpath=%cd%
reg add "%regpath%" /v %evname% /t REG_SZ /d %ANTpath% /f

wmic environment where "name='PATH' and username='<system>'" set VariableValue="%PATH%;%ANTpath%\bin;"


